<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta http-equiv="Pragma" content="no-cache"/>
<meta http-equiv="Cache-Control" content="no-cache"/>
<meta http-equiv="Expires" content="0"/>

<title>客户查询</title>

</head>
<body>

	<form id="form_add" method="post">
		<input type="hidden" id="id" name="id" />
		<div  class="form">
			<s:iterator var="item" value="#attr.columnsTag.column4Add" status="st" >
				<!-- 指定了宽度 -->
				<div id="_${item.columnName}_line" class="text" <s:if test="#item.lineWidth4AddDialog!=0">style="width:${item.lineWidth4AddDialog}px;"</s:if>>
					<script type="text/javascript">
						//所有列备份一下，一会隐藏了，可以恢复
						_columnDivArray[_columnDivArray.length] = '#_${item.columnName}_line';
					</script>
					<label >${item.columnShowName}：</label>
					<div title="${item.columnTip}">
					<s:if test="#item.columnType=='combotree'">
						<select id="${item.columnName}"  name="${item.columnName}" class="easyui-combotree"
							<s:if test="#item.style4AddDialog!=null && #item.style4AddDialog!=''">style="${item.style4AddDialog}"</s:if>
							<s:elseif test="#item.inputWidth4AddDialog!=0">style="width:${item.inputWidth4AddDialog}px;"</s:elseif>
							<s:else>style="width:150px;"</s:else>
							<s:if test="#item.dataOptions4AddDialog!=null && #item.dataOptions4AddDialog!=''">data-options="url:'${item.optionsPage}',${item.dataOptions4AddDialog}"</s:if>
							<s:elseif test="#item.required4AddDialog==0">data-options="url:'${item.optionsPage}',required:false" </s:elseif>
							<s:else>data-options="url:'${item.optionsPage}',required:true"</s:else>
						 >
						 </select>
					</s:if>
					<!-- check is select -->
					<s:elseif test="#item.columnType=='combobox'">
						<s:iterator var="column" value="#attr.templateTableColumnOptionList" status="st1" >
							<s:if test="#column.columnName==#item.columnName">
								<!-- style, data-options -->
								<input class="easyui-combobox" name="${column.columnName}" id="${column.columnName}4Add"
									<s:if test="#item.style4AddDialog!=null && #item.style4AddDialog!=''">style="${item.style4AddDialog}"</s:if>
									<s:elseif test="#item.inputWidth4AddDialog!=0">style="width:${item.inputWidth4AddDialog}px;"</s:elseif>
									<s:else>style="width:150px;"</s:else>
									<s:if test="#item.dataOptions4AddDialog!=null && #item.dataOptions4AddDialog!=''">data-options="valueField:'keyName', textField:'valueName',editable:false,${item.dataOptions4AddDialog}"</s:if>
									<s:elseif test="#item.required4AddDialog==0">data-options="valueField:'keyName', textField:'valueName',required:false,editable:false" </s:elseif>
									<s:else>data-options="valueField:'keyName', textField:'valueName',required:true,editable:false"</s:else>
									/>
								<script type="text/javascript">
									_columnCombobox4AddJsonArray[_columnCombobox4AddJsonArray.length] = '${column.a1TemplateColumnOptionJsonArray}';
									_columnCombobox4AddArray[_columnCombobox4AddArray.length] = '${column.columnName}4Add';
								</script>
							</s:if>
						</s:iterator>
					</s:elseif>

					<s:elseif test="#item.dataTransfer=='date' || #item.dataTransfer=='datetime'">
						<!-- 日期范围 -->
						<input type="text" id="${columnName}" name="${columnName}" size='20'
							   class='<s:if test="#item.dataTransfer=='date'">easyui-datebox</s:if><s:else>easyui-datetimebox</s:else>'
							   <s:if test="#item.style4AddDialog!=null && #item.style4AddDialog!=''">style="${item.style4AddDialog}"</s:if>
							   <s:elseif test="#item.inputWidth4AddDialog!=0">style="width:${item.inputWidth4AddDialog}px;"</s:elseif>
							   <s:else>style="width:150px;"</s:else>
							   <s:if test="#item.dataOptions4AddDialog!=null && #item.dataOptions4AddDialog!=''">data-options="${item.dataOptions4AddDialog}"</s:if>
							   <s:elseif test="#item.required4AddDialog==0">data-options="required:false" </s:elseif>
							   <s:else>data-options="required:true"</s:else> />
					</s:elseif>

						<!-- Input -->
					<s:else>
						<!-- style, data-options -->
						<input class="easyui-validatebox"  type="text"  name="${item.columnName}"
							<s:if test="#item.style4AddDialog!=null && #item.style4AddDialog!=''">style="${item.style4AddDialog}"</s:if>
							<s:elseif test="#item.inputWidth4AddDialog!=0">style="width:${item.inputWidth4AddDialog}px;"</s:elseif>
							<s:else>style="width:150px;"</s:else>
							<s:if test="#item.dataOptions4AddDialog!=null && #item.dataOptions4AddDialog!=''">data-options="${item.dataOptions4AddDialog}"</s:if>
							<s:elseif test="#item.required4AddDialog==0">data-options="required:false" </s:elseif>
							<s:else>data-options="required:true"</s:else>
							/>
					</s:else>
					</div>
				</div>
			</s:iterator>
			<div class="clearboth"></div>
		</div>
	</form>

</body>
</html>




